home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 April: Mac OS SDK / Dev.CD Apr 98 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Universal / Interfaces / PInterfaces / CMMComponent.p < prev    next >
Encoding:
Text File  |  1998-02-12  |  7.8 KB  |  187 lines  |  [TEXT/MPS ]

  1. {
  2.      File:        CMMComponent.p
  3.  
  4.      Contains:    ColorSync CMM Component API
  5.  
  6.      Version:    Technology:    ColorSync 2.5
  7.                  Release:    Universal Interfaces 3.1
  8.  
  9.      Copyright:    © 1994-1998 by Apple Computer, Inc., all rights reserved.
  10.  
  11.      Bugs?:        Please include the the file and version information (from above) with
  12.                  the problem description.  Developers belonging to one of the Apple
  13.                  developer programs can submit bug reports to:
  14.  
  15.                      devsupport@apple.com
  16.  
  17. }
  18. {$IFC UNDEFINED UsingIncludes}
  19. {$SETC UsingIncludes := 0}
  20. {$ENDC}
  21.  
  22. {$IFC NOT UsingIncludes}
  23.  UNIT CMMComponent;
  24.  INTERFACE
  25. {$ENDC}
  26.  
  27. {$IFC UNDEFINED __CMMCOMPONENT__}
  28. {$SETC __CMMCOMPONENT__ := 1}
  29.  
  30. {$I+}
  31. {$SETC CMMComponentIncludes := UsingIncludes}
  32. {$SETC UsingIncludes := 1}
  33.  
  34. {$IFC UNDEFINED __QUICKDRAW__}
  35. {$I Quickdraw.p}
  36. {$ENDC}
  37. {$IFC UNDEFINED __COMPONENTS__}
  38. {$I Components.p}
  39. {$ENDC}
  40. {$IFC UNDEFINED __CMAPPLICATION__}
  41. {$I CMApplication.p}
  42. {$ENDC}
  43.  
  44.  
  45. {$PUSH}
  46. {$ALIGN MAC68K}
  47. {$LibExport+}
  48.  
  49.  
  50. CONST
  51.     CMMInterfaceVersion            = 1;
  52.  
  53. { Component function selectors }
  54. { Required }
  55.     kCMMInit                    = 0;
  56.     kNCMMInit                    = 6;
  57.     kCMMMatchColors                = 1;
  58.     kCMMCheckColors                = 2;
  59.  
  60. { Optional }
  61.     kCMMValidateProfile            = 8;
  62.     kCMMFlattenProfile            = 14;
  63.     kCMMUnflattenProfile        = 15;
  64.     kCMMMatchBitmap                = 9;
  65.     kCMMCheckBitmap                = 10;
  66.     kCMMMatchPixMap                = 3;
  67.     kCMMCheckPixMap                = 4;
  68.     kCMMConcatenateProfiles        = 5;
  69.     kCMMConcatInit                = 7;
  70.     kCMMNewLinkProfile            = 16;
  71.     kCMMGetPS2ColorSpace        = 11;
  72.     kCMMGetPS2ColorRenderingIntent = 12;
  73.     kCMMGetPS2ColorRendering    = 13;
  74.     kCMMGetPS2ColorRenderingVMSize = 17;
  75.     kCMMGetNamedColorInfo        = 70;
  76.     kCMMGetNamedColorValue        = 71;
  77.     kCMMGetIndNamedColorValue    = 72;
  78.     kCMMGetNamedColorIndex        = 73;
  79.     kCMMGetNamedColorName        = 74;
  80.  
  81.  
  82. FUNCTION NCMInit(CMSession: ComponentInstance; srcProfile: CMProfileRef; dstProfile: CMProfileRef): CMError;
  83.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  84.     INLINE $2F3C, $0008, $0006, $7000, $A82A;
  85.     {$ENDC}
  86. FUNCTION CMInit(CMSession: ComponentInstance; srcProfile: CMProfileHandle; dstProfile: CMProfileHandle): CMError;
  87.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  88.     INLINE $2F3C, $0008, $0000, $7000, $A82A;
  89.     {$ENDC}
  90. FUNCTION CMMatchColors(CMSession: ComponentInstance; VAR myColors: CMColor; count: UInt32): CMError;
  91.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  92.     INLINE $2F3C, $0008, $0001, $7000, $A82A;
  93.     {$ENDC}
  94. FUNCTION CMCheckColors(CMSession: ComponentInstance; VAR myColors: CMColor; count: UInt32; VAR result: LONGINT): CMError;
  95.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  96.     INLINE $2F3C, $000C, $0002, $7000, $A82A;
  97.     {$ENDC}
  98.  
  99. { Optional functions }
  100. FUNCTION CMMValidateProfile(CMSession: ComponentInstance; prof: CMProfileRef; VAR valid: BOOLEAN): CMError;
  101.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  102.     INLINE $2F3C, $0008, $0008, $7000, $A82A;
  103.     {$ENDC}
  104. FUNCTION CMMFlattenProfile(CMSession: ComponentInstance; prof: CMProfileRef; flags: UInt32; proc: CMFlattenUPP; refCon: UNIV Ptr): CMError;
  105.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  106.     INLINE $2F3C, $0010, $000E, $7000, $A82A;
  107.     {$ENDC}
  108. FUNCTION CMMUnflattenProfile(CMSession: ComponentInstance; VAR resultFileSpec: FSSpec; proc: CMFlattenUPP; refCon: UNIV Ptr): CMError;
  109.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  110.     INLINE $2F3C, $000C, $000F, $7000, $A82A;
  111.     {$ENDC}
  112. FUNCTION CMMatchBitmap(CMSession: ComponentInstance; {CONST}VAR bitmap: CMBitmap; progressProc: CMBitmapCallBackUPP; refCon: UNIV Ptr; VAR matchedBitmap: CMBitmap): CMError;
  113.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  114.     INLINE $2F3C, $0010, $0009, $7000, $A82A;
  115.     {$ENDC}
  116. FUNCTION CMCheckBitmap(CMSession: ComponentInstance; {CONST}VAR bitmap: CMBitmap; progressProc: CMBitmapCallBackUPP; refCon: UNIV Ptr; VAR resultBitmap: CMBitmap): CMError;
  117.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  118.     INLINE $2F3C, $0010, $000A, $7000, $A82A;
  119.     {$ENDC}
  120. FUNCTION CMMatchPixMap(CMSession: ComponentInstance; VAR myPixMap: PixMap; progressProc: CMBitmapCallBackUPP; refCon: UNIV Ptr): CMError;
  121.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  122.     INLINE $2F3C, $000C, $0003, $7000, $A82A;
  123.     {$ENDC}
  124. FUNCTION CMCheckPixMap(CMSession: ComponentInstance; {CONST}VAR myPixMap: PixMap; progressProc: CMBitmapCallBackUPP; VAR myBitMap: BitMap; refCon: UNIV Ptr): CMError;
  125.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  126.     INLINE $2F3C, $0010, $0004, $7000, $A82A;
  127.     {$ENDC}
  128. FUNCTION CMConcatInit(CMSession: ComponentInstance; VAR profileSet: CMConcatProfileSet): CMError;
  129.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  130.     INLINE $2F3C, $0004, $0007, $7000, $A82A;
  131.     {$ENDC}
  132. FUNCTION CMNewLinkProfile(CMSession: ComponentInstance; VAR prof: CMProfileRef; {CONST}VAR targetLocation: CMProfileLocation; VAR profileSet: CMConcatProfileSet): CMError;
  133.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  134.     INLINE $2F3C, $000C, $0010, $7000, $A82A;
  135.     {$ENDC}
  136. FUNCTION CMMGetPS2ColorSpace(CMSession: ComponentInstance; srcProf: CMProfileRef; flags: UInt32; proc: CMFlattenUPP; refCon: UNIV Ptr): CMError;
  137.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  138.     INLINE $2F3C, $0010, $000B, $7000, $A82A;
  139.     {$ENDC}
  140. FUNCTION CMMGetPS2ColorRenderingIntent(CMSession: ComponentInstance; srcProf: CMProfileRef; flags: UInt32; proc: CMFlattenUPP; refCon: UNIV Ptr): CMError;
  141.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  142.     INLINE $2F3C, $0010, $000C, $7000, $A82A;
  143.     {$ENDC}
  144. FUNCTION CMMGetPS2ColorRendering(CMSession: ComponentInstance; srcProf: CMProfileRef; dstProf: CMProfileRef; flags: UInt32; proc: CMFlattenUPP; refCon: UNIV Ptr): CMError;
  145.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  146.     INLINE $2F3C, $0014, $000D, $7000, $A82A;
  147.     {$ENDC}
  148. FUNCTION CMMGetPS2ColorRenderingVMSize(CMSession: ComponentInstance; srcProf: CMProfileRef; dstProf: CMProfileRef; VAR vmSize: UInt32): CMError;
  149.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  150.     INLINE $2F3C, $000C, $0011, $7000, $A82A;
  151.     {$ENDC}
  152. FUNCTION CMConcatenateProfiles(CMSession: ComponentInstance; thru: CMProfileHandle; dst: CMProfileHandle; VAR newDst: CMProfileHandle): CMError;
  153.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  154.     INLINE $2F3C, $000C, $0005, $7000, $A82A;
  155.     {$ENDC}
  156. { Named Color functions }
  157. FUNCTION CMMGetNamedColorInfo(CMSession: ComponentInstance; srcProf: CMProfileRef; VAR deviceChannels: UInt32; VAR deviceColorSpace: OSType; VAR PCSColorSpace: OSType; VAR count: UInt32; prefix: StringPtr; suffix: StringPtr): CMError;
  158.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  159.     INLINE $2F3C, $001C, $0046, $7000, $A82A;
  160.     {$ENDC}
  161. FUNCTION CMMGetNamedColorValue(CMSession: ComponentInstance; prof: CMProfileRef; name: StringPtr; VAR deviceColor: CMColor; VAR PCSColor: CMColor): CMError;
  162.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  163.     INLINE $2F3C, $0010, $0047, $7000, $A82A;
  164.     {$ENDC}
  165. FUNCTION CMMGetIndNamedColorValue(CMSession: ComponentInstance; prof: CMProfileRef; index: UInt32; VAR deviceColor: CMColor; VAR PCSColor: CMColor): CMError;
  166.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  167.     INLINE $2F3C, $0010, $0048, $7000, $A82A;
  168.     {$ENDC}
  169. FUNCTION CMMGetNamedColorIndex(CMSession: ComponentInstance; prof: CMProfileRef; name: StringPtr; VAR index: UInt32): CMError;
  170.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  171.     INLINE $2F3C, $000C, $0049, $7000, $A82A;
  172.     {$ENDC}
  173. FUNCTION CMMGetNamedColorName(CMSession: ComponentInstance; prof: CMProfileRef; index: UInt32; name: StringPtr): CMError;
  174.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  175.     INLINE $2F3C, $000C, $004A, $7000, $A82A;
  176.     {$ENDC}
  177. {$ALIGN RESET}
  178. {$POP}
  179.  
  180. {$SETC UsingIncludes := CMMComponentIncludes}
  181.  
  182. {$ENDC} {__CMMCOMPONENT__}
  183.  
  184. {$IFC NOT UsingIncludes}
  185.  END.
  186. {$ENDC}
  187.